---
title: Fix React Native version mismatch
---

Add a [Snapped To Version Group](VERSION_GROUP_SNAPPED_TO) which allows some of the packages in your monorepo to "follow" other packages in terms of which versions they should use.

In this example we want our Mobile App package to be the single source of truth for what the versions of `react` and `react-native` should be. Every other package will be required to use the same version it does.

Here is the Version Group configuration to do it:

- An optional **label** can be added to document the rule.
- The **dependencies** array defines the names of the dependencies we want to target.
- The **snapTo** array lists the `name` properties of the locally developed package.json files which should be searched for a version of `react` or `react-native`.

```json title=".syncpackrc.json"
{
  "versionGroups": [
    {
      "label": "Always use the versions of react brought in by the Mobile App",
      "dependencies": ["react", "react-native"],
      "snapTo": ["mobile-app"]
    }
  ]
}
```
